import { httpData } from '@/utils/types';
import { post, get } from '@/utils/request';
export default {
    // 产线运行记录-工序页面:查询
    procedureSelect: (data?: httpData) => {
        return get('/app/run/record/procedure/select', data);
    },

    // 产线运行记录-工序流程:开启任务
    taskOpen: (data?: httpData) => {
        return post('/app/run/record/procedure/task/open', data);
    },

    // 产线运行记录-工序流程:结束任务
    taskEnd: (data?: httpData) => {
        return post('/app/run/record/procedure/task/end', data);
    },

    // 产线运行记录-工序流程:保存表单记录
    saveFormRecord: (data?: httpData) => {
        return post('/app/run/record/procedure/saveFormRecord', data);
    },
    //*********************************************产线运行工单*********************************************** */

    // 生产管理-产线运行工单
    orderList: (data?: httpData) => {
        return get('/app/run/record/orderList', data);
    },

    // 生产管理-产线运行工单-工艺路径
    processRouteList: (data?: httpData) => {
        return get('/app/run/record/processRouteList', data);
    },

    // 生产管理-产线运行工单-工序流程:设备扫码
    equipmentScan: (data?: httpData) => {
        return get('/app/run/record/procedure/equipmentScan', data);
    },

    //*********************************************产线运行记录*********************************************** */

    // 产线运行记录-工序列表:查询
    procedureList: (data?: httpData) => {
        return get('/app/run/record/procedure/procedureList', data);
    },

    //*********************************************设备运行时长*********************************************** */
    // 产线运行记录-设备运行时长记录:分页查询
    runTimeList: (data?: httpData) => {
        return get('/app/run/record/procedure/equipment/run/time/record/list', data);
    },

    // 产线运行记录-设备运行时长记录:设备扫码
    runEquipmentScan: (data?: httpData) => {
        return post('/app/run/record/procedure/equipment/run/time/record/equipmentScan', data);
    },

    // 产线运行记录-设备运行时长记录:开启运行
    runRecordStart: (data?: httpData) => {
        return post('/app/run/record/procedure/equipment/run/time/record/start', data);
    },

    // 产线运行记录-设备运行时长记录:开启运行
    runRecordEnd: (data?: httpData) => {
        return post('/app/run/record/procedure/equipment/run/time/record/end', data);
    },

    // 产线运行记录-设备运行时长记录:删除
    runDelete: (data?: httpData) => {
        return post('/app/run/record/procedure/equipment/run/time/record/delete', data);
    },

    //*********************************************运行过程记录*********************************************** */
    // 产线运行记录-设备运行过程记录:设备扫码
    processEquipmentScan: (data?: httpData) => {
        return get('/app/run/record/procedure/equipment/run/process/record/equipmentScan', data);
    },

    // 产线运行记录-设备运行过程记录:提交
    processSubmit: (data?: httpData) => {
        return post('/app/run/record/procedure/equipment/run/process/record/submit', data);
    },

    // 产线运行记录-设备运行过程记录:表单初始化
    formInitialize: (data?: httpData) => {
        return get('/app/run/record/procedure/equipment/run/process/record/formInitialize', data);
    },

    // 产线运行记录-设备运行过程记录:分页查询
    processRecordList: (data?: httpData) => {
        return get('/app/run/record/procedure/equipment/run/process/record/list', data);
    },

    // 巡检方案下拉
    maintainName: (data?: httpData) => {
        return get('/equipment/programme/cycle/dropdown/equipmentProgramme', data);
    },

    //*********************************************采集项目*********************************************** */
    // 产线运行记录-数据采集:数据采集详情信息
    collectionDetailInfo: (data?: httpData) => {
        return get('/app/run/record/collection/collectionDetailInfo', data);
    },

    // 产线运行记录-数据采集:采集项目下拉
    collectionProject: (data?: httpData) => {
        return get('/app/run/record/collection/dropdown/collectionProject', data);
    },

    //产线运行记录-数据采集:新增采集详情
    insertDetail: (data?: httpData) => {
        return post('/app/run/record/collection/insertDetail', data);
    },

    // 开启/关闭项目
    startOrCloseCollectionProject: (data?: httpData) => {
        return post('/app/run/record/collection/collectionProject/startOrClose', data);
    },

    //*********************************************设备报检*********************************************** */
    // 产线运行记录-设备报检:查询
    runRecordProcedureSelect: (data?: httpData) => {
        return get('/app/run/record/procedure/select', data);
    },

    // 产线运行记录-设备报检:新增
    procedureCheckInspectionSave: (data?: httpData) => {
        return post('/app/run/record/procedure/check/inspection/save', data);
    },

    // 产线运行工单-设备报检-新增:物料信息下拉
    pullDownMaterial: (data?: httpData) => {
        return get('/app/run/record/procedure/check/inspection/pullDown/material', data);
    },

    // 设备卡片所有子设备下拉
    dropdownChild: (data?: httpData) => {
        return get('/equipment/card/dropdownChild', data);
    },

    //*********************************************异常中断*********************************************** */
    // 产线运行记录-异常中断:查询
    abnormalList: (data?: httpData) => {
        return get('/app/run/record/abnormal/list', data);
    },

    // 产线运行记录-异常中断:新增
    abnormalSave: (data?: httpData) => {
        return post('/app/run/record/abnormal/save', data);
    },

    //产线运行记录-异常中断:结束（即重新开启工序）
    abnormalEnd: (data?: httpData) => {
        return post('/app/run/record/abnormal/end', data);
    },
};
